package constant;

/**
 * @author caosinuo
 * @date 2019/5/22 11:01
 */
public class Constant {

   public static class ErrorCode {

      /**
       * 无效参数
       */
      public static Integer INVALID_PARAM_CODE = -101;
      public static String INVALID_PARAM_MSG = "无效参数";

      /**
       * 没有权限
       */
      public static Integer PERMISSION_DENIED_CODE = -102;
      public static String PERMISSION_DENIED_MSG = "没有权限";

      /**
       * 通用错误
       */
      public static Integer COMMON_ERROR_CODE = -103;
      public static String COMMON_ERROR_MSG = "服务器繁忙，请稍后再试";

      /**
       * 登录失效
       */
      public static Integer INVALID_LOGIN_CODE = -104;
      public static String INVALID_LOGIN_MSG = "登录失效";

      /**
       * 数据库操作失败
       */
      public static Integer DATABASE_OPERATION_ERROR_CODE = -105;
      public static String DATABASE_OPERATION_ERROR_MSG = "数据库操作失败";

      /**
       * token失效
       */
      public static Integer INVALID_TOKEN_CODE = -106;
      public static String INVALID_TOKEN_MSG = "用户未登录或登录信息已失效";

      /**
       * 服务器异常
       */
      public static Integer SERVER_ERROR_CODE = -200;
      public static String SERVER_ERROR_MSG = "服务器异常";

   }
}
